Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

V1 Automation #101

Open
wants to merge 26 commits into
base: v1-machines
Choose a base branch
from
Open

V1 Automation #101

wants to merge 26 commits into from

Conversation

anttix
Copy link
Owner

@anttix anttix commented Dec 24, 2019

No description provided.

Copy link

@jeffeb3 jeffeb3 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am half distracted ATM. I want to check this out on my computer and poke around with it. I'm really not sure how, for example, we would make the releases for the latest 2.0.1 release.

I am super happy about this though. This is going to really increase the quality.

run: |
v1-scripts/fetch-branch "origin/$BUILD_BRANCH"
git fetch --prune origin "$MIRROR_BRANCH" # We need full history of the mirror branch
git branch $MIRROR_BRANCH origin/$MIRROR_BRANCH
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I might not be getting the order here, but should this be fetching from upstream?

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

N/M, I see the pull action at 15 */6

- name: Push
if: github.event_name != 'pull_request'
run: |
git push origin "$BUILD_BRANCH:refs/heads/$BUILD_BRANCH" --force
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe I don't understand what this is doing...

#bodyFile: "body.md"
token: ${{ secrets.GITHUB_TOKEN }}
prerelease: true
name: unstable
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So this will always go to the same release, right? There won't be a way to get a previous unstable branch?

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are these build products also available in the build log?

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not too happy with existing release plugins. It starts to look like we may have to build one.

In principle one can upload artifacts from build steps that can then be downloaded from the steps. But this is difficult to find/use and it's not designed for long-term storage.

If there is a need to keep a longer history of nightlies these must be published as releases. Which means there must be some cleanup logic to prune these.

MIRROR_BRANCH="${MIRROR_BRANCH:-$UPSTREAM_BRANCH}"
ORIGIN_REMOTE_NAME="${ORIGIN_REMOTE_NAME:-origin}"

PULL_REQUESTS="${PULL_REQUESTS:-16108 16229}"
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These have been merged, so we can get rid of these, right?

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will also only work for PRs against bugfix, otherwise, it will merge stuff not in the PR.

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, these are not needed any more. I keep these around to test the concept.


UPSTREAM_REPOSITORY="${UPSTREAM_REPOSITORY:-https://github.com/MarlinFirmware/Marlin.git}"
UPSTREAM_REMOTE_NAME="${UPSTREAM_REMOTE_NAME:-upstream}"
UPSTREAM_BRANCH="${UPSTREAM_BRANCH:-$UPSTREAM_REMOTE_NAME/bugfix-2.0.x}"
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This could be an argument, to support picking this branch from upstream. I think 2.0.x is probably more useful for us, but bugfix is also useful.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, it is. Because of the '=-'. Got it.

@@ -0,0 +1,22 @@
#!/bin/bash
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I love this step!

MIRROR_BRANCH="${MIRROR_BRANCH:-bugfix-2.0.x}"
MACHINES_BRANCH="${MACHINES_BRANCH:-HEAD}"
BUILD_BRANCH="${BUILD_BRANCH:-v1-$MIRROR_BRANCH}"
ADD_BRANCHES="${ADD_BRANCHES:-v1-base-config}"
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This v1-base-config has to always be based on a common parent, or it will pull inextra stuff, right? I still have this idea in my head that bugfix and releases are not organized well upstream. Not sure how to fix that though.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What if v1-base-config was a submodule (or even just a nested checkout during build).

Copy link
Owner Author

@anttix anttix Dec 24, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The point of these branches is to carry code that needs to be merged in but upstream will not carry. Think about backports of our PR-s that make it work/build on 2.0.x. These are present in bugfix-2.0.x and will be eventually in 2.0.1 but until that happens, backports need to be stored somewhere.

The v1-base-config branch right now is a test of two concepts: Starting with a "base" config that we (hopefully) push to upsteam and this branch merging logic.

. $incdir/drv8825

opt_set DEFAULT_AXIS_STEPS_PER_UNIT "{ 200, 200, 800, 200 }"
opt_enable REVERSE_ENCODER_DIRECTION
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think reverse encoder direction should probably be the same on all the LCD configs. I'm guessing there is an error in the configs that causes this to only be on some setups.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This probably should be put next to the disolay enable feature, which looks like it is in the base configs.


incdir=$(dirname $0)/..

use_example_configs CNC/MPCNC
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You don't want this, do you? This is going to have a chicken and egg problem.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or is this just copying the _Bootscreen?

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This copies the entire config/examples/CNC/MPCNC directory.


opt_enable REVERSE_ENCODER_DIRECTION

# Why?
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No idea. Probably just not as obvious as it is here.

Antti Andreimann added 3 commits February 9, 2020 20:14
Github doesn't allow automated pushes when workflows are present.

! [remote rejected]     HEAD -> v1-bugfix-2.0.x (refusing to allow a bot to create or update workflow `.github/workflows/test-builds.yml`)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants